import java.util.Random;

public class J08random {
    public static void main(String[] args) {
        Random r = new Random();
        //[0,10)   [0,9]
        for (int i = 0; i < 10; i++) {
            int a = r.nextInt(10);
            System.out.println(a);
        }
        System.out.println("=====");
        //[10-20]
        /*
        [0,10]  + 10
         */
        for (int i = 0; i < 10; i++) {
            System.out.println(r.nextInt(11)+10);
        }
        /*
        [min,max]
        伪代码，假代码
        r.nextint(max-min+1) + min
         */

    }
}
